<template>
    <div class="box">
        <p class="title"> ENTER FILE PATH</p>
        <input v-model="path" class="filepathinput"/>
        <button @click="sendfiletrigger">发送</button>
    </div>
</template>
<script>
export default {
    data(){
        return{
            path:''
        }
    },
    methods:{
        sendfiletrigger(){
            if(this.path ==''){
                alert("NO EMPTY PATH")
                return
            }
            this.$emit("sendFileHandler",this.path)
        }
    }
}
</script>
<style scoped>
.box{
    position:absolute;
    top:50%;
    left: 50%;
    flex-direction: column;
    transform:translate(-50%,-50%);
    width: 400px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content:space-around;
    background-color: red;
    box-shadow: 5px 5px 5px 5px black;
}
.title{
    color: white;
}
.filepathinput{
    width: 80%;
}
</style>